<?php
    session_start();
    $status = $_POST['status'];
    $mesager = 0;
    if(!isset($_SESSION['product'])){
        $mesager = 0;
    }
    else{
        foreach($_SESSION['product'] as $key => $value){
            $mesager = $value['num_pro']+ $mesager;
        }
        
    }
    echo $mesager;
    
?>